<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>请求处理</title>
	<%@include file="../common/header.jsp"%>

</head>
<body>
	
	<div id="header">
			<img class="logo_img" alt="" src="static/img/logo.png" >
			<span class="wel_word">课室管理系统</span>
			<%@include file="../common/manager_menu.jsp"%>
	</div>
	
	<div id="main">
		<table>
			<tr>
				<td>日期</td>
				<td>课室编号</td>
				<td>学生学号</td>
				<td>状态</td>
				<td colspan="2">请求</td>
				<td>详细信息</td>
			</tr>

			<c:forEach items="${requestScope.page.items}" var="order">
			<tr>
				<td>${order.createTime}</td>
				<td>${order.classroomId}</td>
				<td>${order.studentId}</td>
				<td>
					<c:if test="${order.status==0}">未审核</c:if>
					<c:if test="${order.status==1}">已拒绝</c:if>
					<c:if test="${order.status==2}">已通过</c:if>
				</td>
					<c:if test="${order.status==0}">
						<td><a href="orderServlet?action=accept&orderId=${order.id}&pageNo=${requestScope.page.pageNo}">同意</a></td>
						<td><a href="orderServlet?action=refuse&orderId=${order.id}&pageNo=${requestScope.page.pageNo}">拒绝</a></td>
					</c:if>
					<c:if test="${order.status>0}">
						<td>同意</td>
						<td>拒绝</td>
					</c:if>
				<td><a href="orderServlet?action=details&orderId=${order.id}&pageNo=${requestScope.page.pageNo}">查看详情</a></td>
			</tr>
			</c:forEach>
		</table>
		<%@include file="../common/page_nav.jsp"%>
	</div>

	<%@include file="../common/footer.jsp"%>

</body>
</html>